package com.ljw.webserviceserver.demo;

import com.ljw.webserviceserver.demo.entity.UserInfo;

import javax.jws.WebService;
import java.util.ArrayList;

/**
 * @Author LiuJunWen
 * @Date 2020/4/28 20:43
 */
@WebService(targetNamespace = "http://demo.webserviceserver.ljw.com/",
        endpointInterface = "com.ljw.webserviceserver.demo.UserWebService")
public class UserWebServiceImpl implements UserWebService {

    @Override
    public String getName(String userId) {
        return "Java";
    }

    @Override
    public UserInfo getUser(String userId) {
        UserInfo userInfo = new UserInfo();
        userInfo.setName("LiLei");
        userInfo.setUserId(userId);
        return userInfo;
    }

    @Override
    public ArrayList<UserInfo> getAlLUser() {
        ArrayList<UserInfo> arrayList = new ArrayList();
        arrayList.add(getUser("1"));
        return arrayList;
    }

}